
<%@ page import="sige.Sangria" %>
<!doctype html>
<html>
	<head>
		<meta name="layout" content="main">
		<g:set var="entityName" value="${message(code: 'sangria.label', default: 'Sangria')}" />
		<title><g:message code="default.list.label" args="[entityName]" /></title>
	</head>
	<body>
		<center>
        	<h1><g:message code="default.list.label" args="[entityName]" /></h1>
        </center>
        <ul class="breadcrumb">
          <li>
            <a class="home" href="${createLink(uri: '/')}">
              <i class="icon-home"></i>
              <g:message code="default.home.label"/>
            </a>
            <span class="divider"><g:message code="span.divider" /></span>
          </li>
          <li>
            <g:link class="create" action="create">
              <i class="icon-file"></i>
              <g:message code="default.new.label" args="[entityName]" />
            </g:link>
          </li>
        </ul>
        <g:if test="${flash.message}">
          <div class="alert alert-info">
            <button type="button" class="close" data-dismiss="alert">&times;</button>
            ${flash.message}
          </div>
        </g:if>
		<div id="list-sangria" class="span12" role="main">
			<g:form action="list" class="form-search">
              <div class="input-append">
                <input type="text" class="span4 search-query">
                <button type="submit" class="btn btn-primary">
                  <i class="icon-search icon-white"></i>
                </button>
              </div>
            </g:form>
			<table class="table table-striped table-hover">
				<thead>
					<tr>
					
						<g:sortableColumn property="descricao" title="${message(code: 'sangria.descricao.label', default: 'Descrição')}" />
					
						<g:sortableColumn property="dataDeVencimento" title="${message(code: 'sangria.dataDeVencimento.label', default: 'Data De Vencimento')}" />
					
						<g:sortableColumn property="valorBase" title="${message(code: 'sangria.valorBase.label', default: 'Valor Base')}" />
					
				    </tr>
				</thead>
				<tbody>
				<g:each in="${sangriaInstanceList}" status="i" var="sangriaInstance">
					<tr class="${(i % 2) == 0 ? 'even' : 'odd'}">
					
						<td><g:link action="show" id="${sangriaInstance.id}">${fieldValue(bean: sangriaInstance, field: "descricao")}</g:link></td>
					
						<td><g:formatDate date="${sangriaInstance.dataDeVencimento}" /></td>
					
						<td>${fieldValue(bean: sangriaInstance, field: "valorBase")}</td>
					
					</tr>
				</g:each>
				</tbody>
			</table>
			<div class="pagination" align="center">
				<g:paginate total="${sangriaInstanceTotal}" />
			</div>
		</div>
	</body>
</html>
